<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.EditExporterItemTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.EditExporterItemLabel_idExporterItem}" for="idExporterItem" />
                    <h:inputText id="idExporterItem" value="#{exporterItemController.selected.idExporterItem}" title="#{bundle.EditExporterItemTitle_idExporterItem}" required="true" requiredMessage="#{bundle.EditExporterItemRequiredMessage_idExporterItem}"/>
                    <h:outputLabel value="#{bundle.EditExporterItemLabel_amount}" for="amount" />
                    <h:inputText id="amount" value="#{exporterItemController.selected.amount}" title="#{bundle.EditExporterItemTitle_amount}" />
                    <h:outputLabel value="#{bundle.EditExporterItemLabel_itemID}" for="itemID" />
                    <h:selectOneMenu id="itemID" value="#{exporterItemController.selected.itemID}" title="#{bundle.EditExporterItemTitle_itemID}" >
                        <f:selectItems value="#{itemController.itemsAvailableSelectOne}"/>
                    </h:selectOneMenu>
                    <h:outputLabel value="#{bundle.EditExporterItemLabel_exporterID}" for="exporterID" />
                    <h:selectOneMenu id="exporterID" value="#{exporterItemController.selected.exporterID}" title="#{bundle.EditExporterItemTitle_exporterID}" >
                        <f:selectItems value="#{exporterController.itemsAvailableSelectOne}"/>
                    </h:selectOneMenu>
                </h:panelGrid>
                <h:commandLink action="#{exporterItemController.update}" value="#{bundle.EditExporterItemSaveLink}"/>
                <br />
                <br />
                <h:commandLink action="View" value="#{bundle.EditExporterItemViewLink}" immediate="true"/>
                <br />
                <h:commandLink action="#{exporterItemController.prepareList}" value="#{bundle.EditExporterItemShowAllLink}" immediate="true"/>
                <br />
                <br />
                <h:commandLink value="#{bundle.EditExporterItemIndexLink}" action="/index" immediate="true" />
            </h:form>
        </ui:define>
    </ui:composition>

</html>
